Limit Linux-only code with Q_OS_LINUX
authorPino Toscano <toscano.pino@tiscali.it>
Thu, 27 Mar 2025 11:24:29 +0000 (14:24 +0300)
committerDmitry Shachnev <mitya57@debian.org>
Thu, 27 Mar 2025 11:24:29 +0000 (14:24 +0300)
commit9737216124ed74f4b2e2fd029a59508ec1c7f617
tree72cec565c22962f78995e8498e3186cb765b95ea
parent51379c86bb047fce5216c7ad9b4441c28c294eb0
Limit Linux-only code with Q_OS_LINUX

Forwarded: no
Last-Update: 2020-04-19

The QStorageInfo/QStorageIterator implementation used for Linux is used also
on Hurd, as it uses an interface provided by GNU libc.
QStorageIterator::device() tries to use PATH_MAX (unavailable on the Hurd)
to lookup a /dev/block/ path, which exists on Linux only; hence, perform that
check within a Q_OS_LINUX block.

Gbp-Pq: Name qstorageinfo_linux.diff
src/corelib/io/qstorageinfo_unix.cpp